package com.bjut.vendormgrsys.web.rest;

import com.bjut.vendormgrsys.web.dto.ResultInfo;
import com.bjut.vendormgrsys.web.dto.ResultList;
import com.bjut.vendormgrsys.web.dto.ResultStatusList;
import com.bjut.vendormgrsys.web.dto.Success;
import com.bjut.vendormgrsys.web.dto.systemVideo.SystemVideoInfo;
import com.bjut.vendormgrsys.web.dto.systemVideo.SystemVideoSearch;
import com.bjut.vendormgrsys.web.dto.user.Body;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.enums.ParameterIn;
import io.swagger.v3.oas.annotations.media.Content;
import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.responses.ApiResponse;
import io.swagger.v3.oas.annotations.responses.ApiResponses;
import org.springframework.http.ResponseEntity;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;

import javax.validation.Valid;
import java.util.List;

@Validated
public interface SystemVideoApi {
    @Operation(summary = "创建精彩视频和修改", description = "创建精彩视频和修改", tags={ "SystemVideo" })
    @ApiResponses(value = {
            @ApiResponse(responseCode = "200", description = "成功", content = @Content(schema = @Schema(implementation = Success.class))) })
    @RequestMapping(value = "/systemVideo/create",
            method = RequestMethod.POST)
    ResponseEntity<Success> systemVideoCreatePost(SystemVideoInfo body);


    @Operation(summary = "获取精彩视频列表", description = "", tags={ "SystemVideo" })
    @ApiResponses(value = {
            @ApiResponse(responseCode = "200", description = "获取精彩视频列表", content = @Content(schema = @Schema(implementation = ResultList.class))) })
    @RequestMapping(value = "/systemVideo/findAll",
            produces = { "application/json;charset=UTF-8" },
            consumes = { "application/json;charset=UTF-8" },
            method = RequestMethod.POST)
    ResponseEntity<ResultList> systemVideoFindAllPost(@Parameter(in = ParameterIn.DEFAULT, description = "", schema = @Schema()) @Valid @RequestBody SystemVideoSearch body);

    @Operation(summary = "状态变更", description = "修改精彩视频状态", tags={ "SystemVideo" })
    @ApiResponses(value = {
            @ApiResponse(responseCode = "200", description = "成功", content = @Content(schema = @Schema(implementation = Success.class))) })
    @RequestMapping(value = "/systemVideo/changeStatus",
            produces = { "application/json;charset=UTF-8" },
            consumes = { "application/json;charset=UTF-8" },
            method = RequestMethod.POST)
    ResponseEntity<Success> changeStatusPost(@Parameter(in = ParameterIn.DEFAULT, description = "", schema = @Schema()) @Valid @RequestBody List<Body> body);

    @Operation(summary = "根据id获取精彩视频信息", description = "根据id获取精彩视频信息", tags={ "SystemVideo" })
    @ApiResponses(value = {
            @ApiResponse(responseCode = "200", description = "成功", content = @Content(schema = @Schema(implementation = Success.class))) })
    @RequestMapping(value = "/systemVideo/newsInfoById",
            produces = { "application/json;charset=UTF-8" },
            method = RequestMethod.GET)
    ResponseEntity<ResultInfo> systemVideoInfoByIdPost(@RequestParam String id);

    @Operation(summary = "状态统计", description = "状态统计", tags={ "SystemVideo" })
    @ApiResponses(value = {
            @ApiResponse(responseCode = "200", description = "成功", content = @Content(schema = @Schema(implementation = Success.class))) })
    @RequestMapping(value = "/systemVideo/statusList",
            method = RequestMethod.GET)
    ResponseEntity<ResultStatusList> statusListPost();

}
